//
//  NSS.swift
//  zifuchuangfenge
//
//  Created by henaihan on 2017/9/24.
//  Copyright © 2017年 henaihan. All rights reserved.
//

import Foundation
extension NSString {
    func split(splitStr:NSString)->[NSString] {
        let scanner = Scanner(string: self as String)
        var arr:[NSString] = []
        while (scanner.isAtEnd == false){
            var subStr:NSString? = ""
            scanner.scanUpTo(splitStr as String, into:
                &subStr)
            arr.append(subStr!)
        }
        return arr
    }
}
